home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1996 March / EnigmA AMIGA RUN 05 (1996)(G.R. Edizioni)(IT)[!][issue 1996-03][Skylink CD IV].iso / earcd / faq / timeg153.lha / TIME_GUIDE / Install / Install_Guide next >
Text File  |  1995-08-12  |  6KB  |  266 lines

  1. ; $VER: Install_Guide 1.51 (12.08.95)
  2. ; Script to install Time.guide
  3.  
  4. (complete 0)
  5.  
  6. (set old_level @user-level)
  7. (set @default-dest "sys:")
  8.  
  9. ;=============================================================================
  10. ; Deutsch strings
  11. ;(if (= @languge "Deutsch")
  12. ;(
  13.    (set #bad-kick
  14.    (cat "Sie benötigen AMIGA OS 2.0+ zum Installieren der "
  15.         "Time.guide!"))
  16.  
  17.     (set #ask-dir    "Wohin soll die Time.guide installiert werden?")
  18.  
  19.     (set #ask-funktion "Was soll installiert werden?\n\n")
  20.     (set #ask1 "AmigaGuide")
  21.     (set #ask2 "Startfiles")
  22.     (set #ask3 "Amiga-Magazin-Liste")
  23.     (set #ask4 "Amiga-Plus-Liste")
  24.     (set #ask5 "SaarAG-Liste")
  25.     (set #ask6 "Time-Liste")
  26.     (set #ask7 "Indizes")
  27.     (set #ask8 "Hilfsprogramme")
  28.     (set #ask9 "Sourcecodes")
  29.     (set #ask-funktion-help
  30.     (cat "\nSie müssen auswählen, was installiert werden soll.\n\n"
  31.         "Mit \"" #ask1 "\" wird dieses auf Ihre Startdisk installiert\n"
  32.         "\"" #ask2 "\" installiert Startfiles zur Time.guide (werden unbedingt benötigt)\n"
  33.         "\"" #ask3 "\" installiert Inhalte der Amiga-Magazin-Disks\n"
  34.         "\"" #ask4 "\" installiert Inhalte der Amiga-Plus-Disks\n"
  35.         "\"" #ask5 "\" installiert Inhalte der SaarAG-Disks\n"
  36.         "\"" #ask6 "\" installiert Inhalte der Time-Disks\n"
  37.         "\"" #ask7 "\" installiert den Index zu allen Serien\n"
  38.         "\"" #ask8 "\" installiert Bestellprogramme\n"
  39.         "\"" #ask9 "\" zu den Hilfsprogrammen\n"
  40.     ))
  41.     (set #ask-funktion-2 "Welche Sprache(n) wollen Sie installieren?\n\n")
  42.  
  43.     (set #Install "Installiere ")
  44.     (set #Proc-Quest "Welche Version der Bestellsoftware soll installiert werden?\n\n")
  45.     (set #Unpack "Entpacke ")
  46.     (set #default_lang 1)
  47. ;))
  48. ;=============================================================================
  49. ; make sure we are running under V37+
  50.  
  51. (if (< (/ (getversion) 65536) 37)
  52.   (
  53.    abort #bad-kick
  54.   )
  55. )
  56.  
  57. ;=============================================================================
  58. ; Verzeichnis auswählen:
  59.  
  60. (user 2)
  61. (set target_dir (askdir (prompt #ask-dir @askdir)
  62.          (help @askdir-help)
  63.             (default @default-dest)
  64.             (disk)
  65.       )
  66. )
  67. (user old_level)
  68. (set @default-dest target_dir)
  69.  
  70. ;=============================================================================
  71. ; Routine zum kopieren/entpacken der Time.guide
  72. (user 2)
  73. (set timesel
  74.     (askoptions (prompt #ask-funktion)
  75.     (help #ask-funktion-help)
  76.     (choices #ask1
  77.                 #ask2
  78.                 #ask3
  79.                 #ask4
  80.                 #ask5
  81.                 #ask6
  82.                 #ask7
  83.                 #ask8
  84.                 #ask9
  85.     )
  86.     (default 2)
  87. ))
  88. (user old_level)
  89.  
  90. (set m 0)
  91. (set n 0)
  92. (while (set Timehier
  93.     (select n #ask1
  94.                 #ask2
  95.                 #ask3
  96.                 #ask4
  97.                 #ask5
  98.                 #ask6
  99.                 #ask7
  100.                 #ask8
  101.                 #ask9
  102.                 ""
  103.     ))
  104. (
  105.     (if (IN Timesel n)
  106.     (
  107.         (set #Name    (select n    "AmigaGuide"
  108.                                         "Startfiles"
  109.                                         "AmiMag"
  110.                                         "AmiPlus"
  111.                                         "Saar"
  112.                                         "Time"
  113.                                         "Indizes"
  114.                                         "Zusatz"
  115.                                         "Source"
  116.                         )
  117.         )
  118.         (set #Complete (* (+ n 1) 11))
  119.         (WORKING (CAT #Unpack Timehier))
  120.         (RUN    (cat "lzx x -r /" #Name ".lzx ram:"))
  121.  
  122.         (if (= n 0)
  123.         (
  124.             (copylib    (prompt "AmigaGuide.library" @copylib)
  125.                         (help   @copylib-help)
  126.                         (source "ram:AmigaGuide/amigaguide.library")
  127.                         (dest "Libs:")
  128.                         (confirm 2)
  129.             )
  130.             (copylib    (prompt "AmigaGuide" @copylib)
  131.                         (help   @copylib-help)
  132.                         (source "ram:AmigaGuide/amigaguide")
  133.                         (dest "c:")
  134.                         (confirm 2)
  135.             )
  136.         ))
  137.         (if (AND (> n 0) (< n 7))
  138.         (
  139.             (copyfiles    (prompt (cat #Install Timehier) @copyfiles)
  140.                             (help   @copyfiles-help)
  141.                             (source (cat "ram:" #Name "/"))
  142.                             (dest target_dir)
  143.                             (all)
  144.             )
  145.         ))
  146.         (if (= n 7)
  147.         (
  148.             (set CPUStr (database "cpu"))
  149.             (if (< CPUStr "68020")
  150.                 (set NewProc 0)
  151.                 (set NewProc 1)
  152.             )
  153.             (if (> @user-level 1)
  154.                 (set NewProc
  155.                     (askchoice    (prompt #Proc-Quest)
  156.                                     (help @askchoice)
  157.                                     (choices "MC68000/10"
  158.                                                 "MC68020/30/40/60"
  159.                                     )
  160.                                     (default NewProc)
  161.                     )
  162.                 )
  163.             )
  164.             (if (< NewProc 1)
  165.                 (
  166.                     (delete (CAT "ram:" #Name "/T_Bestellen.020+"))
  167.                     (delete (CAT "ram:" #Name "/T_Bestellen.020+.info")) 
  168.                 )
  169.                 (
  170.                     (delete (CAT "ram:" #Name "/T_Bestellen")) 
  171.                     (rename (CAT "ram:" #Name "/T_Bestellen.020+")
  172.                               (CAT "ram:" #Name "/T_Bestellen")
  173.                     )
  174.                     (delete (CAT "ram:" #Name "/T_Bestellen.020+.info")) 
  175.                 )
  176.             )
  177.             (if (exists "LOCALE:")
  178.             (
  179.                 (user 2)
  180.                 (set lang
  181.                     (askoptions (prompt #ask-funktion-2)
  182.                                     (help @askoptions-help)
  183.                                     (choices
  184. ;                                                "dansk"
  185.                                                 "deutsch"
  186.                                                 "english"
  187. ;                                                "español"
  188. ;                                                "français"
  189. ;                                                "italiano"
  190. ;                                                "nederlands"
  191. ;                                                "norsk"
  192. ;                                                "portoguês"
  193. ;                                                "svenska"
  194.                                     )
  195.                                     (default #default_lang)
  196.                     )
  197.                 )
  198.                 (user old_level)
  199.  
  200.  
  201.                 (set m 0)
  202.                 (while (set language
  203.                     (select m
  204. ;                                "dansk"
  205.                                 "deutsch"
  206.                                 "english"
  207. ;                                "español"
  208. ;                                "français"
  209. ;                                "italiano"
  210. ;                                "nederlands"
  211. ;                                "norsk"
  212. ;                                "portoguês"
  213. ;                                "svenska"
  214.                                 ""
  215.                 ))
  216.                 (
  217.                     (set LocSource (cat "ram:" #Name "/Locale/Catalogs/" language))
  218.                     (if (exists LocSource)
  219.                     (
  220.                         (if (IN lang m)
  221.                         (
  222.                             (makedir (cat "LOCALE:Catalogs/" language))
  223.                             (run (cat "copy >NIL:" LocSource "/#? Locale:Catalogs/" language " all"))
  224. ; VORSICHT: Guru-Gefahr, deshalb Kommentar! (Wieso? Weis ich nicht!)
  225. ;                            (copyfiles    (prompt (CAT #Install language) @copyfiles)
  226. ;                                            (help   @copyfiles-help)
  227. ;                                            (source (cat LocSource "/"))
  228. ;                                            (dest (CAT "LOCALE:Catalogs/" language))
  229. ;                                            (all)
  230. ;                            )
  231.                         ))
  232.                         (run (cat "delete " LocSource "/#? all"))
  233.                         (run (cat "delete " LocSource))
  234.                     ))
  235.                     (set m (+ m 1))
  236.                 ))
  237.             ))
  238.             (run (cat "delete ram:" #Name "/Locale/#? all"))
  239.             (run (cat "delete ram:" #Name "/Locale"))
  240.             (copyfiles    (prompt (CAT #Install Timehier) @copyfiles)
  241.                             (help   @copyfiles-help)
  242.                             (source (cat "ram:" #Name "/"))
  243.                             (dest target_dir)
  244.                             (all)
  245.             )
  246.             (complete #Complete)
  247.         ))
  248.         (if (= n 8)
  249.         (
  250.             (makedir (TACKON target_dir #Name))
  251.             (copyfiles    (prompt (cat #Install Timehier) @copyfiles)
  252.                             (help   @copyfiles-help)
  253.                             (source "ram:Source/")
  254.                             (dest (TACKON target_dir "Source/"))
  255.                             (all)
  256.             )
  257.         ))
  258.     ))
  259.     (run (cat "delete ram:" #Name "/#? all"))
  260.     (run (cat "delete ram:" #Name))
  261.     (complete #Complete)
  262.     (set n (+ n 1))
  263. ))
  264.  
  265. (complete 100)
  266.